package day04;

import java.util.Scanner;

public class WhieDemo1 {
    public static void main(String[] args) {
        Scanner a = new Scanner(System.in);
        int b = (int) (Math.random()*100+1);
        System.out.println("游戏开始");
        int c = a.nextInt();
        while (c != b){
            if (c>b){
                System.out.println("数字大了，请继续猜");
            }else if (c<b){
                System.out.println("数字小了，请继续猜");
            }
            c = a.nextInt();
        }
        System.out.println("恭喜你猜对了");
    }
}
